<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@page import="com.dao.CommonDAO"%>
<%@page import="com.util.Info"%>
<%@page import="com.util.PageManager"%>
<%@page import="com.model.Familycy"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<%=basePath%>">
    
    <title>可穿戴健康监测系统</title>
    
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">    
	<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
	<meta http-equiv="description" content="This is my page">
	<!--
	<link rel="stylesheet" type="text/css" href="styles.css">
	-->
<LINK rel="shortcut icon" type=image/x-icon href="/images/favicon.ico">
<LINK title=ITeye rel=search type=application/opensearchdescription+xml href="/open_search.xml">
<LINK title="" rel=alternate type=application/rss+xml href="/rss">
<LINK rel=stylesheet type=text/css href="frontfiles/blog.css" media=screen>
<LINK rel=stylesheet type=text/css href="frontfiles/blue.css" media=screen>
<SCRIPT type=text/javascript src="frontfiles/application.js"></SCRIPT>

<SCRIPT type=text/javascript>

  var _gaq = _gaq || [];
  _gaq.push(['_setAccount', 'UA-535605-1']);
  _gaq.push(['_setDomainName', 'iteye.com']);
  _gaq.push(['_trackPageview']);

  (function() {
    var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
    ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
    var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
  })();

</SCRIPT>
  </head>
  
  <BODY>
  <%CommonDAO dao = (CommonDAO)Info.getDao(request,"CommonDAO");  
  Familycy cy = (Familycy)session.getAttribute("cy");
  %>


<jsp:include page="top.jsp"></jsp:include>


<DIV id=content class=clearfix>
<DIV id=main>
<DIV class=blog_main_title> <SPAN>个人信息</SPAN> 
<DIV id=fd></DIV></DIV>

<DIV class=blog_main>
<DIV class=blog_title>
<%Familycy s = (Familycy)dao.findById(cy.getId(),"Familycy"); %>
<form action="cygrinfo.action" method="post" name="f1"  onsubmit="return ck()" enctype ="multipart/form-data">
	<input type="hidden" id="id" name="id" value="<%=s.getId() %>" >
	<table width="100%" cellpadding="1" cellspacing="1" border="0">
		<tr>
			<td align="right"><font size="1">身份证号：</font></td>
			<td><font size="1"><%=s.getIdcard() %> </font></td>
		</tr>
		<tr>
			<td align="right"><font size="1">密码：</font></td>
			<td><font size="1"><input type="password" id="pwd" name="pwd">* </font></td>
		</tr>
		<tr>
			<td align="right"><font size="1">姓名：</font></td>
			<td><font size="1"><input type="text" id="tname" name="tname" value="<%=s.getTname() %>">* </font></td>
		</tr>
		<tr>
			<td align="right"><font size="1">性别：</font></td>
			<td><font size="1">
				<select id="sex" name="sex">
					<option value="男" <%if(s.getSex().equals("男")){out.print("selected==selected");} %>>男</option>
					<option value="女" <%if(s.getSex().equals("女")){out.print("selected==selected");} %>>女</option>
				</select>
			 </font></td>
		</tr>
		<tr>
			<td align="right"><font size="1">电话：</font></td>
			<td><font size="1"><input type="text" id="tel" name="tel" value="<%=s.getTel() %>">* </font></td>
		</tr>
		<tr>
			<td align="right"><font size="1">生日：</font></td>
			<td><font size="1"><%=s.getBirth() %> </font></td>
		</tr>
		
		<tr>
			<td align="right"><font size="1">民族：</font></td>
			<td><font size="1"><%=s.getMz() %></font></td>
		</tr>
		<tr>
			<td align="right"><font size="1">地址：</font></td>
			<td><font size="1"><input type="text" id="addr" name="addr" value="<%=s.getAddr() %>">*</font></td>
		</tr>
		<tr>
			<td align="left" colspan="2"><font size="1">
			<input type="submit" value="提交">
			<input type="reset" value="重置">
			</font></td>
		</tr>
	</table>
</form>
<script type="text/javascript">
	function ck(){
     		if(f1.pwd.value==""){
     			alert("密码不能为空");
     			return false;
     		}if(f1.tname.value==""){
     			alert("姓名不能为空");
     			return false;
     		}if(f1.tel.value==""){
     			alert("电话不能为空");
     			return false;
     		}if(f1.addr.value==""){
     			alert("地址不能为空");
     			return false;
     		}
     	}
</script>
</DIV>
</DIV>

  <div align="center">${page.info }</div>
</DIV>
<jsp:include page="indexleft.jsp"></jsp:include>

</DIV>


<jsp:include page="foot.jsp"></jsp:include>


<SCRIPT type=text/javascript>
  document.write("<img src='http://stat.iteye.com/?url="+ encodeURIComponent(document.location.href) + "&referrer=" + encodeURIComponent(document.referrer) + "&user_id=' width='0' height='0' />");
</SCRIPT>
<script type="text/javascript">
    	<%
		String suc = (String)request.getAttribute("suc");
		if(suc!=null){%>
		 alert("操作成功");
		 parent.location.replace("/wearablehealthymonitorsys/stuinfo.jsp");
		 <%}%>
</script>
</BODY></HTML>
